<!--
  @author heguanghua
  @since 2019/06/12 19:34
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<table class="layui-hide" id="zmn-table" lay-filter="zmn-table" th:fragment="table">
    <thead>
    <tr>
        <th lay-data="{field:'stage', width:190, unresize:true, align:'center'}">阶段</th>
        <th lay-data="{field:'amount', unresize:true, align:'center',width:180}">金额</th>
        <th lay-data="{field:'agreedPaymentDay', unresize:true, align:'center',width:180}">约定收付时间</th>
        <th lay-data="{field:'payment', unresize:true, align:'center',width:180}">是否收付</th>
        <th lay-data="{field:'actualPaymentDay', unresize:true, align:'center',width:200}">实际收付时间</th>
        <th lay-data="{field:'remark', unresize:true, align:'center'}">备注</th>
        <th lay-data="{field:'操作', width:200, unresize:true, align:'center', fixed:'right'}">操作</th>
    </tr>
    </thead>

    <tbody>
    <tr th:each="item:${items}">
        <td th:text="${T(com.zmn.plat.common.dictionary.ContractPaymentStageEnum).of(item.stage).name}">stage</td>
        <td th:text="${#numbers.formatDecimal(item.amount / 100.0, 1, 2)}">amount</td>
        <td th:text="${T(com.zmn.common.utils.date.DateUtil).toString(item.agreedPaymentDay, 'yyyy-MM-dd')}">agreedPaymentDay</td>
        <td th:text="${item.payment == 2 ? '是': '否'}">payment</td>
        <td th:text="${T(com.zmn.common.utils.date.DateUtil).toString(item.actualPaymentDay, 'yyyy-MM-dd')}">actualPaymentDay</td>
        <td th:text="${item.remark}">remark</td>
        <td>
            <a th:if="${#authPermit.checkPermit('/contract/payment/record/detail.action')}" style="color: #00a0e9" th:onclick="modifyContractPaymentRecord([[${item.contractId}]], [[${item.relateId}]]);">修改</a>
        </td>
    </tr>
    </tbody>
</table>
